nextafter, nexttoward
From cppreference.com
| Defined in header <math.h>
|
||
| float nextafterf( float from, float to ); |
(since C99) | |
| double nextafter( double from, double to ); |
(since C99) | |
| long double nextafterl( long double from, long double to ); |
(since C99) | |
| float nexttowardf( float from, long double to ); |
(since C99) | |
| double nexttoward( double from, long double to ); |
(since C99) | |
| long double nexttowardl( long double from, long double to ); |
(since C99) | |
Returns the next representable value of from in the direction of to. If from equals to to, to is returned.
If from is finite, but the result of nextafter or nexttoward is infinite, raises FE_OVERFLOW and FE_INEXACT. If the result is subnormal or zero and from != to, raises FE_UNDERFLOW and FE_INEXACT. In any case, the returned value is independent of the current rounding mode.
Contents |
[edit] Parameters
| from, to | - | floating point values |
[edit] Return value
The next representable value of from in the direction of to.
[edit] Example
| This section is incomplete Reason: no example |
[edit] See also
| C++ documentation for nextafter
|